﻿using XLua;

namespace Yoozoo.Gameplay.RTS.Proto
{
    [GCOptimize]
    [LuaCallCSharp]
    public struct MapMonsterL3
    {
        public long npcUid;
        public Coordinate coordinate;
        public int npcId;
        public int npcConfigType;//fieldMonster里的type
        public Coordinate[] pathList;
        public long lastFrameTime; //服务器在上一帧的计算时间
        public float speed; //行军速度
        public MarchStatus marchStatus;
        public int useCnt; //使用次数，用于区分是否是新对象
        public int soldierType;
        public long allianceId;
        // 读配置表获取
        public int[] heroList;
        public int level;
        public string[] heroIconList;
        public int[] heroRageList;
        public int[] rageMaxList;
        public int fomationId;
        public RtsNpcType npcType;
        public string heroBgIcon;
        public long attackTargetId;
        public TargetCoordinateType attackTargetType;
        public TargetCoordinateType troopType;
        public int team;
        public float radius;
        public bool isShowAssemblyHeadFrame;
        public bool IsWonderNpc()
        {
            return npcType == RtsNpcType.NPC_MIRACLE_GUARD || npcType == RtsNpcType.NPC_MIRACLE_MOBILIZATION ||
                   npcType == RtsNpcType.NPC_MIRACLE_REINFORCE || npcType == RtsNpcType.NPC_SP_MONSTER || npcType == RtsNpcType.NPC_SANTA || npcType == RtsNpcType.NPC_CARGO_MONSTER;
        }
        public bool IsBKIARMYNpc()
        {
            return npcType == RtsNpcType.NPC_BKI_ARMY;
        }
    }
}
